home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 9930 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.3 KB

  1. Path: newshost.lanl.gov!tanmoy
  2. From: tanmoy@qcd.lanl.gov (Tanmoy Bhattacharya)
  3. Newsgroups: comp.lang.c
  4. Subject: Re: Pointer to int
  5. Date: 14 Mar 1996 15:13:44 GMT
  6. Organization: Los Alamos National Laboratory
  7. Distribution: world
  8. Message-ID: <TANMOY.96Mar14081344@qcd.lanl.gov>
  9. References: <4i76vf$58v@dunlop.cs.strath.ac.uk>
  10. NNTP-Posting-Host: qcd.lanl.gov
  11. Mime-Version: 1.0
  12. Content-Type: text
  13. In-reply-to: abrown@cs.strath.ac.uk's message of 13 Mar 1996 19:17:03 GMT
  14.  
  15. In article <4i76vf$58v@dunlop.cs.strath.ac.uk>
  16. abrown@cs.strath.ac.uk (Andrew Brown) writes:
  17.  
  18. AB: I have a function that takes as a parameter a pointer to an int. Is it 
  19. AB: possible to pass the address of a constant directly to the function?
  20.  
  21. Sorry, constants don't have addresses in C. So, you can't pass them
  22. either :-)
  23.  
  24. AB:   x = function( &1000 );
  25.  
  26. &1000 is meaningless.
  27.  
  28. Cheers
  29. Tanmoy
  30. --
  31. tanmoy@qcd.lanl.gov(128.165.23.46) DECNET: BETA::"tanmoy@lanl.gov"(1.218=1242)
  32. Tanmoy Bhattacharya O:T-8(MS B285)LANL,NM87545 H:#9,3000,Trinity Drive,NM87544
  33. Others see <gopher://yaleinfo.yale.edu:7700/00/Internet-People/internet-mail>,
  34. <http://alpha.acast.nova.edu/cgi-bin/inmgq.pl>or<ftp://csd4.csd.uwm.edu/pub/
  35. internetwork-mail-guide>. -- <http://nqcd.lanl.gov/people/tanmoy/tanmoy.html>
  36. fax: 1 (505) 665 3003   voice: 1 (505) 665 4733    [ Home: 1 (505) 662 5596 ]
  37.